Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(grid_real), | intent(in) | :: | slope |
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | public | :: | i | ||||
integer, | public | :: | j |
SUBROUTINE ComputeSlopeFactor & ! (slope) IMPLICIT NONE !Arguments with intent in TYPE (grid_real), INTENT (IN) :: slope !local declarations: INTEGER :: i,j !------------end of declaration------------------------------------------------ CALL NewGrid (slopeFactor, slope) DO j = 1, slope % jdim DO i = 1, slope % idim IF (slope % mat (i,j) /= slope % nodata) THEN slopeFactor % mat (i,j) = 1.05 - 0.85 * EXP( -4.0 * SIN(slope % mat(i,j)) ) IF ( slopeFactor % mat (i,j) < 0.2) THEN !filter negative value due to negative slope in pits slopeFactor % mat (i,j) = 0.2 END IF END IF END DO END DO RETURN END SUBROUTINE ComputeSlopeFactor